package com.aabte.permissionframeworklearn.permission.mapper;

import com.aabte.permissionframeworklearn.permission.model.SysAclModule;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface SysAclModuleMapper {
    int deleteByPrimaryKey(Long id);

    int insert(SysAclModule record);

    int insertSelective(SysAclModule record);

    SysAclModule selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(SysAclModule record);

    int updateByPrimaryKey(SysAclModule record);

    int countByNameAndParentId(@Param("name") String aclModuleName, @Param("parentId") Long parentId, @Param("id") Long id);

    List<SysAclModule> getChildAclModuleListByLevel(@Param("level") String level);

    int batchUpdateLevel(@Param("childAclModules") List<SysAclModule> childAclModules);

    List<SysAclModule> getAllAclModule();

    int countByParentId(@Param("parentId") Long id);
}